package com.lxw.api.cms;

import com.lxw.framework.domain.cms.CmsPage;
import com.lxw.framework.domain.cms.request.QueryPageRequest;
import com.lxw.framework.domain.cms.response.CmsPageResult;
import com.lxw.framework.domain.course.response.CoursePublishResult;
import com.lxw.framework.model.response.QueryResponseResult;
import com.lxw.framework.model.response.ResponseResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

@Api(value="CmsPage管理Controller",description = "负责页面增删改查,页面预览,发布等功能")
public interface CmsPageControllerApi {
    //获取cmsPage信息
    @ApiOperation("分页获取cmsPage信息")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "页码",name = "page",paramType = "path",dataType = "Integer",required = true),
            @ApiImplicitParam(value = "每页显示条数",name = "size",paramType = "path",dataType = "Integer",required = true),
           // @ApiImplicitParam(value = "CmsPage请求参数对象",name = "queryPageRequest",paramType = "query",dataType = "QueryPageRequest",required = false)
    })
    public QueryResponseResult findCmsPages(Integer page, Integer size, QueryPageRequest queryPageRequest);

    //增加页面信息
    @ApiOperation("增加页面信息")
    public CmsPageResult addCmsPage(CmsPage cmsPage);

    //根据id获取页面信息
    @ApiOperation("根据id获取页面信息")
    public CmsPageResult findCmsPageById(String id);

    //更新页面信息
    @ApiOperation("更新页面信息")
    public CmsPageResult updateCmsPageById(String id,CmsPage cmsPage);

    //根据id删除页面信息
    @ApiOperation("根据id删除页面信息")
    public ResponseResult deleteCmsPageById(String id);

      //
      @ApiOperation("页面发布")
      public ResponseResult PostCmsPageById(String id);

      //增加或修改页面信息
      @ApiOperation("增加或修改页面信息")
      public CmsPageResult saveCmsPage(CmsPage cmsPage);

      @ApiOperation("一键发布页面")
      public CoursePublishResult postPageQuick(CmsPage cmsPage);

}
